import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/home'
import My from '@/components/My'
import friendsPrivilege from '@/components/friendsPrivilege'
import Card from '@/components/CardBag'
import privilegeDetails from '@/components/privilegeDetails'
import ShopDetails from '@/components/ShopDetails'
import GivePrivilege from '@/components/GivePrivilege'
import Recharge from '@/components/Recharge'
import RechargeSuccess from '@/components/RechargeSuccess'
import Details from '@/components/Details'
import BusinessAddress from '@/components/BusinessAddress'
import BindingPhone from '@/components/BindingPhone'
import RecordsConsumption from '@/components/RecordsConsumption'
import StoreConsumptionRecords from '@/components/StoreConsumptionRecords'
import Saoma from '@/components/Saoma'
import Setup from '@/components/Setup'
import Sharedincome from '@/components/Sharedincome'
import Payment from '@/components/Payment'
import PaymentSuccess from '@/components/PaymentSuccess'
Vue.use(Router)

export default new Router({

  routes: [
    { path: '/', redirect: '/home' },
    {
      path: '/home',
      name: 'home',
      component: HelloWorld,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/My',
      name: 'My',
      component: My,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/friendsPrivilege',
      name: 'friendsPrivilege',
      component: friendsPrivilege,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/CardBag',
      name: 'Car',
      component: Card,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/privilegeDetails',
      name: 'privilegeDetails',
      component: privilegeDetails,
      meta: {
        isPhone: true
      }
      //亲友特权
    }, {
      path: '/ShopDetails',
      name: 'ShopDetails',
      component: ShopDetails,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/GivePrivilege',
      name: 'GivePrivilege',
      component: GivePrivilege,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/Recharge',
      name: 'Recharge',
      component: Recharge,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/RechargeSuccess',
      name: 'RechargeSuccess',
      component: RechargeSuccess,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/Details',
      name: 'Details',
      component: Details,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/BusinessAddress',
      name: 'BusinessAddress',
      component: BusinessAddress,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/BindingPhone',
      name: 'BindingPhone',
      component: BindingPhone,
      meta: {
        isPhone: false
      }
    },

    {
      path: '/RecordsConsumption',
      name: 'RecordsConsumption',
      component: RecordsConsumption,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/StoreConsumptionRecords',
      name: 'StoreConsumptionRecords',
      component: StoreConsumptionRecords,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/Sao',
      name: 'Saoma',
      component: Saoma,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/Setup',
      name: 'Setup',
      component: Setup,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/Sharedincome',
      name: 'Sharedincome',
      component: Sharedincome,
      meta: {
        isPhone: true
      }
    }, {
      path: '/Payment',
      name: 'Payment',
      component: Payment,
      meta: {
        isPhone: true
      }
    },
    {
      path: '/PaymentSuccess',
      name: 'PaymentSuccess',
      component: PaymentSuccess,
      meta: {
        isPhone: true
      }
    },
  ]
})
